import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import './mock/index.js'

// 将axios挂载到Vue实例,在组件中可以直接使用
Vue.config.productionTip = false

// 使用vant
import Vant from  './vant/index'
//全局css引用
import './style/index.css'
// 注册axios
Vue.use(Vant)

const jumpPage=function(path){
  this.$router.push({path})
}
Vue.prototype.navigateTo=jumpPage

const toAuthRoute=function(to,redirect){
  this.$router.replace({path:to,query:{redirect}})
}
Vue.prototype.toAuthRoute=toAuthRoute
Vue.config.productionTip = false

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
